**********************************************************************
Monsters
**********************************************************************

There are 224 enemies in Lufia 2. Most of their properties are stored 
in what I call the "Monster Compendium".

-----------------------------------------------------------------------
Monster data - the "Monster Compendium"
-----------------------------------------------------------------------

[$0B07C0 -> $0B097F]:  pointers to data at [$0B0980]
                       (2 bytes, little-endian (i.e. "least significant 
                                                      byte first"))

                       448 bytes => 224 pointers.
                       Add $0B07C0 to the pointers to find the offsets
                       of the Monster Compendium "entries".

                       Example:
                       [$0B07C0 -> $0B07C1]: $C0 01
                       => pointer: $01C0
                       => offset: $01C0 + $0B07C0 = $0B0980
                       => The first Monster Compendium entry starts 
                          at offset [$0B0980]

[$0B0980 -> $0B5168]:  "Monster Compendium"

                       224 entries:
                       [$0B0980]:  Goblin       
                       [$0B09A5]:  Armor goblin 
                       ...
                       [$0B5087]:  Gades        
                       [$0B50F1]:  Master       

- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 
Format of the Monster Compendium entries:
- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 

   13 "name bytes"
 + 20 "stats bytes"
[+  3 "gift bytes"]
[+  3 bytes for the pointer to the attack script]
[+  3 bytes for the pointer to the defense script]
 +  1 "end byte" ($00)
[+  a variable number of bytes for the attack script]
[+  a variable number of bytes for the defense script]


([+ ...] = optional)


Start offset of the Monster Compendium entry: 
[+$0000]

- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 
"Name bytes":
- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 

[+$0000 -> +$000C] (bytes  0 -> 12):  Name of the monster

    13 characters.

    Example:
    $ 52   65   64   20   A4   65   6C   6C   79   20   20   20   20
     "R"  "e"  "d"  " "  "J"  "e"  "l"  "l"  "y"  " "  " "  " "  " "

- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 
"Stats bytes":
- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 
 
[+$000D]           (byte 13)       :  Level

[+$000E]           (byte 14)       :  ???

    The use of this byte is unkown.
    Encountered values:

    $36 for 'Armor goblin' and 'Regal Goblin'
    $32 for all other monsters

[+$000F]           (byte 15)       :  Battle sprite

    There are 134 enemy battle sprites ($01 -> $86)

[+$0010]           (byte 16)       :  Palette for battle sprite
    
    Some examples:

    Monster:        Battle sprite number:       Palette number:

    Torrent         $4D                         $00
    Mad Ent         $4D                         $01

    Red Jelly       $6E                         $00
    Blue Jelly      $6E                         $01
    Bili Jelly      $6E                         $02

    Tank            $7E                         $00

    !!! This doesn't mean that 'Torrent', 'Red Jelly' and 'Tank' 
        share the same palette (this is not the case).

[+$0011 -> +$0012] (bytes 17 -> 18):  Max HP

    2 bytes, little-endian.

[+$0013 -> +$0014] (bytes 19 -> 20):  Max MP

    2 bytes, little-endian.

[+$0015 -> +$0016] (bytes 21 -> 22):  ATP

    2 bytes, little-endian.

[+$0017 -> +$0018] (bytes 23 -> 24):  DFP

    2 bytes, little-endian.

[+$0019]           (byte 25)       :  AGL / 2

[+$001A]           (byte 26)       :  INT / 2

[+$001B]           (byte 27)       :  GUT / 2

[+$001C]           (byte 28)       :  MGR / 2

[+$001D -> +$001E] (bytes 29 -> 30):  EXP

    2 bytes, little-endian.

[+$001F -> +$0020] (bytes 31 -> 32):  GOLD

    2 bytes, little-endian.

- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 
"Gift bytes":
- - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - 

If there's a $03 after the EXP and GOLD bytes (=> at offset [+$0021], 
it means that the enemy can drop an item. 

Format of the "gift bytes" 

$03 XX YY 
(!!! this $03 is not the L2BASM opcode $03) 

$XX = the low byte of the item number 

$YY = high byte of the item number (always $00 or $01) + p 

      p is a number related to the probability of getting 
      the item, maybe probability * 4. It's always an even number. 

Example:

Gift bytes of the Vampire: $03 73 65 
  $65 = $64 + $01 
  => item number: $0173 (Bat rock) 
  => p = $64 = 100 = 4 * 25 
     => 25 % (?) chances that a defeated Vampire 
        will drop a Bat rock 
